package com.drum.demo.serviceimpl;

import com.drum.demo.bean.Student;
import com.drum.demo.dao.StudentDao;
import com.drum.demo.service.StudentService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import java.util.List;

/**
 * 实行学生服务接口
 *
 * @author XM
 * @version 1.0
 * @Date 2019/3/27 11:15
 */
//@SuppressWarnings("SpringJavaInjectionPointsAutowiringInspection")
@Service("StudentService")
@Transactional(readOnly = true, rollbackFor = Exception.class)
public class StudentServiceImpl implements StudentService {
    @Autowired
    StudentDao studentDao;
    @Override
    public List<Student> getStudentList(String sname, Integer age) {
        return studentDao.getStudentList(sname,age);
    }
}
